#include<bits/stdc++.h>
using namespace std;
#define int long long 
typedef vector<int> ve;
typedef vector<ve> vee;
const int inf=0x3f3f3f3f;


signed main()
{
    int n;cin>>n;
    int b=inf;
    int cnt=0;
    while(n<=1&&b<=1)
    {
        cnt++;
        if(n&1)//如果是奇数
        {
          b=(3*n+1)/2;  
        }
        else 
        {
            n=n/2;
        }
    }
    cout<<cnt<<endl; 
    return 0;
}